<?php session_start(); ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>View Information</title>
<script type="text/javascript" src="validateInformation.js" ></script>


<link href="style.css" rel="stylesheet" type="text/css" />
<style type="text/css">
</style>
</head>

<body>
<table width="100%" border="0" cellpadding="1">
 
  <tr>
    <td>&nbsp;</td>
    <td class="subBanner"><strong> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;View Payment Record</strong></td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td><form id="form1" name="form1" method="post" action="" onsubmit="return validateStudentNo(this)">
      <table width="100%" border="0" cellpadding="1">
        <tr>
          <td width="34%">&nbsp;</td>
          <td class=confirm1 width="43%">Enter Student Number</td>
          <td width="23%" class="error" id="lname">&nbsp;</td>
        </tr>
        <tr>
          <td >&nbsp;</td>
          <td class="confirm1">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
            <input name="searchNum" type="text" id="searchNum" size="4" />
            -
  <input name="searchNum2" type="text" id="searchNum2" size="10" />
  <input name="search" type="submit" id="search3" value="SEARCH"/>
  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
          <td >&nbsp;</td>
        </tr>
        <tr>
          <td>&nbsp;</td>
		  <td id="snum" class="error">&nbsp;</td>
          <td >&nbsp;</td>
          <td >&nbsp;</td>
        </tr>
        </table>
    </form>
    <?php
		require_once 'SearchManager.php';
		if(isset($_POST['search'])){
			$snum = $_POST['searchNum'].$_POST['searchNum2'];

			if($snum!=" "||$snum!=""){
				$flag = SearchManager::searchPayment("snum",$snum,"null");
				if($flag==0){
					echo"<script>alert(\"Student Not Found!\")</script>";
				}
				
			}else{
				echo"<script>alert(\"Please enter Student Number!\")</script>";
			}
	}

	?>
    
    </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>
</body>
</html>

